home *** CD-ROM | disk | FTP | other *** search
/ FM Towns: Free Software Collection 7 / FM Towns Free Software Collection 7.iso / taropyon / zmodem / src / sz.h < prev    next >
C/C++ Source or Header  |  1993-11-30  |  2KB  |  79 lines

  1. #ifndef    _SZ_H
  2. #define    _SZ_H
  3.  
  4. #ifdef XARGSFILE
  5. static    char    *mystrsave(char *s);
  6. static    void    uncrlf( register char *s );
  7. #endif
  8. static    int        wcsend(int argc, char *argp[]);
  9. static    int        wcs(char *oname);
  10. static    int        wctxpn(char *name);
  11. static    int        getnak(void);
  12. static    int        wctx(long flen);
  13. static    int        wcputsec(char *buf, int sectnum, int cseclen);
  14. static    int        filbuf(register char *buf, int count);
  15. static    int        zfilbuf(void);
  16. #ifdef TXBSIZE
  17. static    int        fooseek(FILE * fptr, long pos, int whence);
  18. #endif
  19. static    void    vfile( CONST char *form, ... );
  20. #ifndef    __TOWNS__
  21. static    void    alrm(void);
  22. #endif
  23. static    int        readline(int timeout);
  24. static    void    flushmo(void);
  25. static    void    purgeline(void);
  26. static    void    canit(void);
  27. #ifdef    __HIGHC__
  28. static    void    zperr(char *form, ... );
  29. #else
  30. static    void    zperr(char *s, char *p, char *u);
  31. #endif
  32. static    char    *substr(register char *s, register char *t);
  33. static    int        getzrxinit(void);
  34. static    int        sendzsinit(void);
  35. static    int        zsendfile(char *buf, int blen);
  36. static    int        zsendfdata(void);
  37. static    int        getinsync(int flag);
  38. static    void    saybibi(void);
  39. static    void    bttyout(int c);
  40. static    int        zsendcmd(char *buf, int blen);
  41. static    void    chkinvok(char *s);
  42. static    void    countem(int argc, register char **argv);
  43. static    void    chartest(int m);
  44.  
  45. #define    sendline(_c)    RS_putc(RsPort,(_c) & 0xFF)
  46. #define    xsendline(_c)    RS_putc(RsPort,(_c) & 0xFF)
  47.  
  48. #define    PATHLEN        256
  49. #define    OK            0
  50. #ifndef    FALSE
  51. #    define    FALSE    0
  52. #endif
  53. #ifdef    TRUE
  54. #    undef    TRUE
  55. #endif
  56. #define TRUE        1
  57. #define ERROR        (-1)
  58. /* Ward Christensen / CP/M parameters - Don't change these! */
  59. #define ENQ            005
  60. #define CAN            ('X'&037)
  61. #define XOFF        ('s'&037)
  62. #define XON            ('q'&037)
  63. #define SOH            1
  64. #define STX            2
  65. #define EOT            4
  66. #define ACK            6
  67. #define NAK            025
  68. #define CPMEOF        032
  69. #define WANTCRC        0103        /* send C not NAK to get crc not checksum */
  70. #define WANTG        0107        /* Send G not NAK to get nonstop batch xmsn */
  71. #define TIMEOUT        (-2)
  72. #define RCDO        (-3)
  73. #define GCOUNT        (-4)
  74. #define RETRYMAX    10
  75.  
  76. static    void    usage(void);
  77.  
  78. #endif
  79.